home *** CD-ROM | disk | FTP | other *** search
/ Aminet 1 (Walnut Creek) / Aminet - June 1993 [Walnut Creek].iso / usenet / sources / volume2 / editors / dme1313.of6 < prev    next >
Text File  |  1988-10-22  |  64KB  |  1,639 lines

  1. Path: xanth!nic.MR.NET!hal!cwjcc!mailrus!uflorida!gatech!bbn!ulowell!page
  2. From: page@swan.ulowell.edu (Bob Page)
  3. Newsgroups: comp.sources.amiga
  4. Subject: v02i011:  dme - programmer's text editor V1.31, Part03/06
  5. Message-ID: <9773@swan.ulowell.edu>
  6. Date: 22 Oct 88 04:31:29 GMT
  7. Organization: University of Lowell, Computer Science Dept.
  8. Lines: 1628
  9. Approved: page@swan.ulowell.edu
  10.  
  11. Submitted-by: dillon@cory.berkeley.edu (Matt Dillon)
  12. Posting-number: Volume 2, Issue 11
  13. Archive-name: editors/dme131.3of6
  14.  
  15. # This is a shell archive.  Remove anything before this line
  16. # then unpack it by saving it in a file and typing "sh file"
  17. # (Files unpacked will be owned by you and have default permissions).
  18. # This archive contains the following files:
  19. #    ./src/filereq.c
  20. #    ./src/rexx/rxslib.h
  21. #    ./src/rexx/rxslib.i
  22. #    ./src/rexx/rexxio.h
  23. #    ./src/rexx/rexxio.i
  24. #    ./src/rexx/errors.h
  25. #    ./src/rexx/errors.i
  26. #    ./src/rexx/rxsupplib.i
  27. #    ./src/rexx/storage.h
  28. #    ./src/rexx/storage.i
  29. #    ./src/tags
  30. #
  31. if `test ! -d ./src`
  32. then
  33.   mkdir ./src
  34.   echo "mkdir ./src"
  35. fi
  36. if `test ! -s ./src/filereq.c`
  37. then
  38. echo "writing ./src/filereq.c"
  39. cat > ./src/filereq.c << '\Rogue\Monster\'
  40.  
  41. /*
  42.  *  ARP interface (ARPLOAD, ARPSAVE)
  43.  */
  44.  
  45. #include "defs.h"
  46.  
  47. void
  48. do_arpinsfile()
  49. {
  50.     char file[64];
  51.     char dir[64];
  52.     long oldlock = CurrentDir(Ep->dirlock);
  53.  
  54.     splitpath(Ep->Name, file, dir);
  55.     if (arpreq("INSERTFILE", file, dir, NULL)) {
  56.     CurrentDir(oldlock);
  57.     fixfile(file, dir);
  58.     av[0] = (ubyte *)"i";
  59.     av[1] = (ubyte *)file;
  60.     do_edit();
  61.     return;
  62.     }
  63.     CurrentDir(oldlock);
  64. }
  65.  
  66. void
  67. do_arpload()
  68. {
  69.     char file[64];
  70.     char dir[64];
  71.     long oldlock = CurrentDir(Ep->dirlock);
  72.  
  73.     splitpath(Ep->Name, file, dir);
  74.     if (arpreq("NEWFILE", file, dir, NULL)) {
  75.     long newlock;
  76.     if (newlock = Lock(dir, SHARED_LOCK)) {
  77.         UnLock(CurrentDir(oldlock));
  78.         Ep->dirlock = newlock;
  79.         /*
  80.         fixfile(file,dir);
  81.         */
  82.         av[0] = (ubyte *)"n";
  83.         av[1] = (ubyte *)file;
  84.         do_edit();
  85.         return;
  86.     }
  87.     }
  88.     CurrentDir(oldlock);
  89. }
  90.  
  91. void
  92. do_arpsave()
  93. {
  94.     char file[64];
  95.     char dir[64];
  96.     long oldlock = CurrentDir(Ep->dirlock);
  97.  
  98.     splitpath(Ep->Name, file, dir);
  99.     if (arpreq("SAVEAS", file, dir, NULL)) {
  100.     CurrentDir(oldlock);
  101.     fixfile(file,dir);
  102.     av[1] = (ubyte *)file;
  103.     do_saveas();
  104.     } else {
  105.     CurrentDir(oldlock);
  106.     }
  107. }
  108.  
  109. fixfile(file,dir)
  110. register char *file,*dir;
  111. {
  112.     register char *ptr;
  113.     register short len = strlen(dir);
  114.     char hasdev = 0;
  115.  
  116.     /*
  117.      *    do we need to add a slash to the directory spec?
  118.      */
  119.  
  120.     if (len && dir[len-1] != '/' && dir[len-1] != ':') {
  121.     dir[len++] = '/';
  122.     dir[len] = 0;
  123.     }
  124.  
  125.     /*
  126.      *    Is file spec really a full path spec?
  127.      */
  128.  
  129.     for (ptr = file; *ptr; ++ptr) {
  130.     if (ptr[0] == ':')
  131.         hasdev = 1;
  132.     }
  133.     if (!hasdev) {
  134.     movmem(file,file+len,strlen(file)+1);
  135.     movmem(dir,file,len);
  136.     }
  137. }
  138.  
  139. /*
  140.  *  Search backwards for first ':' or '/' and split path there.
  141.  *  This subroutine may appear to be coded incorrectly to a novice
  142.  *  programmer.  It isn't [now].
  143.  */
  144.  
  145. splitpath(name, file, dir)
  146. register char *name;
  147. char *file, *dir;
  148. {
  149.     register short i;
  150.     for (i = strlen(name); i >= 0; --i) {       /* was (incorrectly) "i > 0" */
  151.     if (name[i] == ':' || name[i] == '/')
  152.         break;
  153.     }
  154.     ++i;
  155.     strcpy(file, name + i);
  156.     bmov(name, dir, i);
  157.     dir[i] = 0;
  158. }
  159.  
  160. #asm
  161.  
  162.         ;   arpreq(hail,file,dir,window)
  163.  
  164.         FAR DATA
  165.         FAR CODE
  166.  
  167.         public    _arpreq
  168.         public    _LVOOldOpenLibrary
  169.         public    _LVOCloseLibrary
  170.         public    _SysBase
  171.  
  172. _LVOFileRequest equ    -294
  173.  
  174. arp_name_text    dc.b 'arp.library',0
  175.  
  176. fs        ds.l    1   ;hailing text
  177.         ds.l    1   ;file name
  178.         ds.l    1   ;directory
  179.         ds.l    1   ;window requesting
  180.         ds.w    1   ;LONG Align, idiots!  set to 0
  181.         ds.l    1   ;func for wildcards
  182.         ds.l    1   ;func to call w/intuimessages
  183.  
  184. _arpreq:
  185.         lea.l    fs,A0
  186.         movem.l 4(sp),D0-D3             ;setup fields
  187.         movem.l D0-D3,(A0)
  188.         clr.w    fs+16
  189.         move.l    _SysBase,A6
  190.  
  191.         lea.l    arp_name_text,a1    ;open library
  192.         jsr    _LVOOldOpenLibrary(a6)
  193.         tst.l    d0
  194.         beq.s    done
  195.         move.l    d0,a6
  196.         lea.l    fs,a0
  197.         jsr    _LVOFileRequest(A6)     ;call requestor
  198.         move.l    D0,-(sp)                ;return value
  199.         move.l    A6,A1            ;CloseLibrary(arpbase)
  200.         move.l    _SysBase,A6
  201.         jsr    _LVOCloseLibrary(A6)
  202.         move.l    (sp)+,D0                ;return value
  203. done        rts
  204.  
  205. #endasm
  206.  
  207.  
  208. \Rogue\Monster\
  209. else
  210.   echo "will not over write ./src/filereq.c"
  211. fi
  212. if [ `wc -c ./src/filereq.c | awk '{printf $1}'` -ne 3110 ]
  213. then
  214. echo `wc -c ./src/filereq.c | awk '{print "Got " $1 ", Expected " 3110}'`
  215. fi
  216. if `test ! -d ./src/rexx`
  217. then
  218.   mkdir ./src/rexx
  219.   echo "mkdir ./src/rexx"
  220. fi
  221. if `test ! -s ./src/rexx/rxslib.h`
  222. then
  223. echo "writing ./src/rexx/rxslib.h"
  224. cat > ./src/rexx/rxslib.h << '\Rogue\Monster\'
  225. /* === rexx/rxslib.h ===================================================
  226.  *
  227.  * Copyright (c) 1986, 1987 by William S. Hawes (All Rights Reserved)
  228.  *
  229.  * =====================================================================
  230.  * The header file for the REXX Systems Library
  231.  */
  232.  
  233. #ifndef REXX_RXSLIB_H
  234. #define REXX_RXSLIB_H
  235.  
  236. #ifndef REXX_STORAGE_H
  237. #include "rexx/storage.h"
  238. #endif
  239.  
  240. /* Some macro definitions                                               */
  241.  
  242. #define RXSNAME  "rexxsyslib.library"
  243. #define RXSID    "rexxsyslib 1.0 (23 AUG 87)\n"
  244. #define RXSDIR   "REXX"
  245. #define RXSTNAME "ARexx"
  246.  
  247. /* The REXX systems library structure.  This should be considered as    */
  248. /* semi-private and read-only, except for documented exceptions.        */
  249.  
  250. struct RxsLib {
  251.    struct Library rl_Node;             /* EXEC library node             */
  252.    UBYTE    rl_Flags;                  /* global flags                  */
  253.    UBYTE    rl_pad;
  254.    APTR     rl_SysBase;                /* EXEC library base             */
  255.    APTR     rl_DOSBase;                /* DOS library base              */
  256.    APTR     rl_IeeeDPBase;             /* IEEE DP math library base     */
  257.    LONG     rl_SegList;                /* library seglist               */
  258.    LONG     rl_MaxAlloc;               /* maximum memory allocation     */
  259.    LONG     rl_Chunk;                  /* allocation quantum            */
  260.    LONG     rl_MaxNest;                /* maximum expression nesting    */
  261.    struct NexxStr *rl_NULL;            /* static string: NULL           */
  262.    struct NexxStr *rl_FALSE;           /* static string: FALSE          */
  263.    struct NexxStr *rl_TRUE;            /* static string: TRUE           */
  264.    struct NexxStr *rl_REXX;            /* static string: REXX           */
  265.    struct NexxStr *rl_COMMAND;         /* static string: COMMAND        */
  266.    struct NexxStr *rl_STDIN;           /* static string: STDIN          */
  267.    struct NexxStr *rl_STDOUT;          /* static string: STDOUT         */
  268.    struct NexxStr *rl_STDERR;          /* static string: STDERR         */
  269.    STRPTR    rl_Version;               /* version/configuration string  */
  270.  
  271.    STRPTR    rl_TaskName;              /* name string for tasks         */
  272.    LONG      rl_TaskPri;               /* starting priority             */
  273.    LONG      rl_TaskSeg;               /* startup seglist               */
  274.    LONG      rl_StackSize;             /* stack size                    */
  275.    STRPTR    rl_RexxDir;               /* REXX directory                */
  276.    STRPTR    rl_CTABLE;                /* character attribute table     */
  277.    struct NexxStr *rl_Notice;          /* copyright notice              */
  278.  
  279.    struct MsgPort rl_RexxPort;         /* REXX public port              */
  280.    UWORD     rl_ReadLock;              /* lock count                    */
  281.    LONG      rl_TraceFH;               /* global trace console          */
  282.    struct List rl_TaskList;            /* REXX task list                */
  283.    WORD      rl_NumTask;               /* task count                    */
  284.    struct List rl_LibList;             /* Library List header           */
  285.    WORD      rl_NumLib;                /* library count                 */
  286.    struct List rl_ClipList;            /* ClipList header               */
  287.    WORD      rl_NumClip;               /* clip node count               */
  288.    struct List rl_MsgList;             /* pending messages              */
  289.    WORD      rl_NumMsg;                /* pending count                 */
  290.    };
  291.  
  292. /* Global flag bit definitions for RexxMaster                           */
  293. #define RLFB_TRACE RTFB_TRACE          /* interactive tracing?          */
  294. #define RLFB_HALT  RTFB_HALT           /* halt execution?               */
  295. #define RLFB_SUSP  RTFB_SUSP           /* suspend execution?            */
  296. #define RLFB_TCUSE RTFB_TCUSE          /* trace console in use?         */
  297. #define RLFB_TCOPN 4                   /* trace console open?           */
  298. #define RLFB_STOP  6                   /* deny further invocations      */
  299. #define RLFB_CLOSE 7                   /* close the master              */
  300.  
  301. #define RLFMASK    0x07                /* passed flags                  */
  302.  
  303. /* Initialization constants                                             */
  304.  
  305. #define RXSVERS    2                   /* main version                  */
  306. #define RXSREV     1                   /* revision                      */
  307. #define RXSALLOC   0x800000            /* maximum allocation            */
  308. #define RXSCHUNK   1024                /* allocation quantum            */
  309. #define RXSNEST    32                  /* expression nesting limit      */
  310. #define RXSTPRI    0                   /* task priority                 */
  311. #define RXSSTACK   4096                /* stack size                    */
  312. #define RXSLISTH   4                   /* number of list headers        */
  313.  
  314. /* Character attribute flag bits used in REXX.  Defined only for        */
  315. /* ASCII characters (range 0-127).                                      */
  316.  
  317. #define CTB_SPACE   0                  /* white space characters        */
  318. #define CTB_DIGIT   1                  /* decimal digits 0-9            */
  319. #define CTB_ALPHA   2                  /* alphabetic characters         */
  320. #define CTB_REXXSYM 3                  /* REXX symbol characters        */
  321. #define CTB_REXXOPR 4                  /* REXX operator characters      */
  322. #define CTB_REXXSPC 5                  /* REXX special symbols          */
  323. #define CTB_UPPER   6                  /* UPPERCASE alphabetic          */
  324. #define CTB_LOWER   7                  /* lowercase alphabetic          */
  325.                                                                       
  326. /* Attribute flags                                                      */
  327. #define CTF_SPACE   (1 << CTB_SPACE)
  328. #define CTF_DIGIT   (1 << CTB_DIGIT)
  329. #define CTF_ALPHA   (1 << CTB_ALPHA)
  330. #define CTF_REXXSYM (1 << CTB_REXXSYM)
  331. #define CTF_REXXOPR (1 << CTB_REXXOPR)
  332. #define CTF_REXXSPC (1 << CTB_REXXSPC)
  333. #define CTF_UPPER   (1 << CTB_UPPER)
  334. #define CTF_LOWER   (1 << CTB_LOWER)
  335.  
  336. #endif
  337. \Rogue\Monster\
  338. else
  339.   echo "will not over write ./src/rexx/rxslib.h"
  340. fi
  341. if [ `wc -c ./src/rexx/rxslib.h | awk '{printf $1}'` -ne 6046 ]
  342. then
  343. echo `wc -c ./src/rexx/rxslib.h | awk '{print "Got " $1 ", Expected " 6046}'`
  344. fi
  345. if `test ! -s ./src/rexx/rxslib.i`
  346. then
  347. echo "writing ./src/rexx/rxslib.i"
  348. cat > ./src/rexx/rxslib.i << '\Rogue\Monster\'
  349. * === rexx/rxslib.i ====================================================
  350. *
  351. * Copyright (c) 1986, 1987 by William S. Hawes (All Rights Reserved)
  352. *
  353. * ======================================================================
  354. * Include file for the REXX Systems Library
  355.  
  356.          IFND     REXX_RXSLIB_I
  357. REXX_RXSLIB_I  SET   1
  358.  
  359.          IFND     REXX_STORAGE_I
  360.          INCLUDE  "rexx/storage.i"
  361.          ENDC
  362.  
  363.          ; Macro definitions 
  364.  
  365. RXSNAME  MACRO
  366.          dc.b     'rexxsyslib.library',0
  367.          ENDM
  368.  
  369. RXSID    MACRO
  370.          dc.b     'rexxsyslib 1.02 (01 NOV 87)',10,0
  371.          ENDM
  372.  
  373. RXSDIR   MACRO                         ; directory (device) for programs
  374.          dc.b     'REXX',0
  375.          ENDM
  376.  
  377. RXSTNAME MACRO                         ; name for tasks
  378.          dc.b     'ARexx',0
  379.          ENDM
  380.  
  381. * Macro to call a library function (assumes library pointer is in A6)
  382. CALLSYS  MACRO    * FunctionName
  383.          CALLLIB  _LVO\1
  384.          ENDM
  385.  
  386. * Macro to define an external library entry point (offset)
  387. XLIB     MACRO    * FunctionName
  388.          XREF     _LVO\1
  389.          ENDM
  390.  
  391. * Structure definition for the REXX systems library
  392.          STRUCTURE RxsLib,LIB_SIZE     ; EXEC library node
  393.          UBYTE    rl_Flags             ; global flags
  394.          UBYTE    rl_pad
  395.          APTR     rl_SysBase           ; EXEC library base
  396.          APTR     rl_DOSBase           ; DOS library base
  397.          APTR     rl_IeeeDPBase        ; IEEE DP math library base
  398.          LONG     rl_SegList           ; library seglist
  399.          LONG     rl_MaxAlloc          ; maximum memory allocation
  400.          LONG     rl_Chunk             ; allocation quantum
  401.          LONG     rl_MaxNest           ; maximum expression nesting
  402.          APTR     rl_NULL              ; static string: NULL
  403.          APTR     rl_FALSE             ; static string: FALSE
  404.          APTR     rl_TRUE              ; static string: TRUE
  405.          APTR     rl_REXX              ; static string: REXX
  406.          APTR     rl_COMMAND           ; static string: COMMAND
  407.          APTR     rl_STDIN             ; static string: STDIN
  408.          APTR     rl_STDOUT            ; static string: STDOUT
  409.          APTR     rl_STDERR            ; static string: STDERR
  410.          APTR     rl_Version           ; version string
  411.  
  412.          LONG     rl_TaskName          ; name string for tasks
  413.          LONG     rl_TaskPri           ; starting priority
  414.          LONG     rl_TaskSeg           ; startup seglist
  415.          LONG     rl_StackSize         ; stack size
  416.          APTR     rl_RexxDir           ; REXX directory
  417.          APTR     rl_CTABLE            ; character attribute table
  418.          APTR     rl_Notice            ; copyright notice
  419.  
  420.          STRUCT   rl_RexxPort,MP_SIZE  ; public port
  421.          UWORD    rl_ReadLock          ; lock count
  422.          APTR     rl_TraceFH           ; global trace console
  423.          STRUCT   rl_TaskList,LH_SIZE  ; REXX task list
  424.          WORD     rl_NumTask
  425.          STRUCT   rl_LibList,LH_SIZE   ; Library List header
  426.          WORD     rl_NumLib
  427.          STRUCT   rl_ClipList,LH_SIZE  ; ClipList header
  428.          WORD     rl_NumClip
  429.          STRUCT   rl_MsgList,LH_SIZE   ; pending messages
  430.          WORD     rl_NumMsg
  431.          LABEL    rl_SIZEOF
  432.  
  433. * Global flag bit definitions for RexxMaster
  434. RLFB_TRACE  EQU   RTFB_TRACE           ; interactive tracing?
  435. RLFB_HALT   EQU   RTFB_HALT            ; halt execution?
  436. RLFB_SUSP   EQU   RTFB_SUSP            ; suspend execution?
  437. RLFB_TCUSE  EQU   RTFB_TCUSE           ; trace console in use?
  438. RLFB_TCOPN  EQU   4                    ; trace console open?
  439. RLFB_STOP   EQU   6                    ; deny further invocations
  440. RLFB_CLOSE  EQU   7                    ; close the master
  441.  
  442. RLFMASK     EQU      $07               ; passed flags
  443.  
  444.          ; Initialization constants
  445.  
  446. RXSVERS  EQU      2                    ; main version
  447. RXSREV   EQU      1                    ; revision
  448. RXSALLOC EQU      $800000              ; maximum allocation
  449. RXSCHUNK EQU      1024                 ; allocation quantum
  450. RXSNEST  EQU      32                   ; expression nesting limit
  451. RXSTPRI  EQU      0                    ; task priority
  452. RXSSTACK EQU      4096                 ; stack size
  453. RXSLISTH EQU      4                    ; number of list headers
  454.  
  455. * The library entry point offsets
  456.          LIBINIT
  457.          LIBDEF   _LVORexx             ; Main entry point
  458.          LIBDEF   _LVOrxParse          ; (private)
  459.          LIBDEF   _LVOrxInstruct       ; (private)
  460.          LIBDEF   _LVOrxSuspend        ; (private)
  461.          LIBDEF   _LVOEvalOp           ; (private)
  462.  
  463.          LIBDEF   _LVOAssignValue      ; (private)
  464.          LIBDEF   _LVOEnterSymbol      ; (private)
  465.          LIBDEF   _LVOFetchValue       ; (private)
  466.          LIBDEF   _LVOLookUpValue      ; (private)
  467.          LIBDEF   _LVOSetValue         ; (private)
  468.          LIBDEF   _LVOSymExpand        ; (private)
  469.  
  470.          LIBDEF   _LVOErrorMsg
  471.          LIBDEF   _LVOIsSymbol
  472.          LIBDEF   _LVOCurrentEnv
  473.          LIBDEF   _LVOGetSpace
  474.          LIBDEF   _LVOFreeSpace
  475.  
  476.          LIBDEF   _LVOCreateArgstring
  477.          LIBDEF   _LVODeleteArgstring
  478.          LIBDEF   _LVOLengthArgstring
  479.          LIBDEF   _LVOCreateRexxMsg
  480.          LIBDEF   _LVODeleteRexxMsg
  481.          LIBDEF   _LVOClearRexxMsg
  482.          LIBDEF   _LVOFillRexxMsg
  483.          LIBDEF   _LVOIsRexxMsg
  484.  
  485.          LIBDEF   _LVOAddRsrcNode
  486.          LIBDEF   _LVOFindRsrcNode
  487.          LIBDEF   _LVORemRsrcList
  488.          LIBDEF   _LVORemRsrcNode
  489.          LIBDEF   _LVOOpenPublicPort
  490.          LIBDEF   _LVOClosePublicPort
  491.          LIBDEF   _LVOListNames
  492.  
  493.          LIBDEF   _LVOClearMem
  494.          LIBDEF   _LVOInitList
  495.          LIBDEF   _LVOInitPort
  496.          LIBDEF   _LVOFreePort
  497.  
  498.          LIBDEF   _LVOCmpString
  499.          LIBDEF   _LVOStcToken
  500.          LIBDEF   _LVOStrcmpN
  501.          LIBDEF   _LVOStrcmpU
  502.          LIBDEF   _LVOStrcpyA
  503.          LIBDEF   _LVOStrcpyN
  504.          LIBDEF   _LVOStrcpyU
  505.          LIBDEF   _LVOStrflipN
  506.          LIBDEF   _LVOStrlen
  507.          LIBDEF   _LVOToUpper
  508.  
  509.          LIBDEF   _LVOCVa2i
  510.          LIBDEF   _LVOCVi2a
  511.          LIBDEF   _LVOCVi2arg
  512.          LIBDEF   _LVOCVi2az
  513.          LIBDEF   _LVOCVc2x
  514.          LIBDEF   _LVOCVx2c
  515.  
  516.          LIBDEF   _LVOOpenF
  517.          LIBDEF   _LVOCloseF
  518.          LIBDEF   _LVOReadStr
  519.          LIBDEF   _LVOReadF
  520.          LIBDEF   _LVOWriteF
  521.          LIBDEF   _LVOSeekF
  522.          LIBDEF   _LVOQueueF
  523.          LIBDEF   _LVOStackF
  524.          LIBDEF   _LVOExistF
  525.  
  526.          LIBDEF   _LVODOSCommand
  527.          LIBDEF   _LVODOSRead
  528.          LIBDEF   _LVODOSWrite
  529.          LIBDEF   _LVOCreateDOSPkt
  530.          LIBDEF   _LVODeleteDOSPkt
  531.          LIBDEF   _LVOSendDOSPkt
  532.          LIBDEF   _LVOWaitDOSPkt
  533.          LIBDEF   _LVOFindDevice
  534.  
  535.          LIBDEF   _LVOAddClipNode
  536.          LIBDEF   _LVORemClipNode
  537.          LIBDEF   _LVOLockRexxBase
  538.          LIBDEF   _LVOUnlockRexxBase
  539.  
  540. * Character attribute flag bits used in REXX.  Attributes are defined only
  541. * for ASCII characters (range 0-127).
  542. CTB_SPACE   EQU   0                    ; white space characters
  543. CTB_DIGIT   EQU   1                    ; decimal digits 0-9
  544. CTB_ALPHA   EQU   2                    ; alphabetic characters
  545. CTB_REXXSYM EQU   3                    ; REXX symbol characters
  546. CTB_REXXOPR EQU   4                    ; REXX operator characters
  547. CTB_REXXSPC EQU   5                    ; REXX special symbols
  548. CTB_UPPER   EQU   6                    ; UPPERCASE alphabetic
  549. CTB_LOWER   EQU   7                    ; lowercase alphabetic
  550.  
  551. * Attribute flags
  552. CTF_SPACE   EQU   1<<CTB_SPACE
  553. CTF_DIGIT   EQU   1<<CTB_DIGIT
  554. CTF_ALPHA   EQU   1<<CTB_ALPHA
  555. CTF_REXXSYM EQU   1<<CTB_REXXSYM
  556. CTF_REXXOPR EQU   1<<CTB_REXXOPR
  557. CTF_REXXSPC EQU   1<<CTB_REXXSPC
  558. CTF_UPPER   EQU   1<<CTB_UPPER
  559. CTF_LOWER   EQU   1<<CTB_LOWER
  560.  
  561.          ENDC
  562. \Rogue\Monster\
  563. else
  564.   echo "will not over write ./src/rexx/rxslib.i"
  565. fi
  566. if [ `wc -c ./src/rexx/rxslib.i | awk '{printf $1}'` -ne 7722 ]
  567. then
  568. echo `wc -c ./src/rexx/rxslib.i | awk '{print "Got " $1 ", Expected " 7722}'`
  569. fi
  570. if `test ! -s ./src/rexx/rexxio.h`
  571. then
  572. echo "writing ./src/rexx/rexxio.h"
  573. cat > ./src/rexx/rexxio.h << '\Rogue\Monster\'
  574. /* === rexx/rexxio.h ====================================================
  575.  *
  576.  * Copyright (c) 1986, 1987 by William S. Hawes (All Rights Reserved)
  577.  *
  578.  * ======================================================================
  579.  * Header file for ARexx Input/Output related structures
  580.  */
  581.  
  582. #ifndef REXX_REXXIO_H
  583. #define REXX_REXXIO_H
  584.  
  585. #ifndef REXX_STORAGE_H
  586. #include "rexx/storage.h"
  587. #endif
  588.  
  589. #define RXBUFFSZ  204                  /* buffer length                 */
  590.  
  591. /* The IoBuff is a resource node used to maintain the File List.  Nodes are
  592.  * allocated and linked into the list whenever a file is opened.
  593.  */
  594.  
  595. struct IoBuff {
  596.    struct RexxRsrc iobNode;            /* structure for files/strings   */
  597.    APTR     iobRpt;                    /* read/write pointer            */
  598.    LONG     iobRct;                    /* character count               */
  599.    LONG     iobDFH;                    /* DOS filehandle                */
  600.    APTR     iobLock;                   /* DOS lock                      */
  601.    LONG     iobBct;                    /* buffer length                 */
  602.    BYTE     iobArea[RXBUFFSZ];         /* buffer area                   */
  603.    };                                  /* size: 256 bytes               */
  604.  
  605. /* Access mode definitions                                              */
  606. #define RXIO_EXIST   -1                /* an external filehandle        */
  607. #define RXIO_STRF    0                 /* a "string file"               */
  608. #define RXIO_READ    1                 /* read-only access              */
  609. #define RXIO_WRITE   2                 /* write mode                    */
  610. #define RXIO_APPEND  3                 /* append mode (existing file)   */
  611.  
  612. /* Offset anchors for SeekF()                                           */
  613. #define RXIO_BEGIN   -1                /* relative to start             */
  614. #define RXIO_CURR    0                 /* relative to current position  */
  615. #define RXIO_END     1                 /* relative to end               */
  616.  
  617. /* The Library List contains just plain resource nodes.                 */
  618.  
  619. #define LLOFFSET(rrp) (rrp->rr_Arg1)   /* "Query" offset                */
  620. #define LLVERS(rrp)   (rrp->rr_Arg2)   /* library version               */
  621.  
  622. /* The RexxClipNode structure is used to maintain the Clip List.  The
  623.  * value string is stored as an argstring in the rr_Arg1 field.
  624.  */
  625.  
  626. #define CLVALUE(rrp) ((STRPTR) rrp->rr_Arg1)
  627.  
  628. /* A message port structure, maintained as a resource node.
  629.  * The ReplyList holds packets that have been received but haven't been
  630.  * replied.
  631.  */
  632.  
  633. struct RexxMsgPort {
  634.    struct RexxRsrc rmp_Node;           /* linkage node                  */
  635.    struct MsgPort  rmp_Port;           /* the message port              */
  636.    struct List     rmp_ReplyList;      /* messages awaiting reply       */
  637.    };
  638.  
  639. /* DOS Device types                                                     */
  640. #define DT_DEV    0                    /* a device                      */
  641. #define DT_DIR    1                    /* an ASSIGNed directory         */
  642. #define DT_VOL    2                    /* a volume                      */
  643.  
  644. /* Private DOS packet types                                             */
  645. #define ACTION_STACK 2002              /* stack a line                  */
  646. #define ACTION_QUEUE 2003              /* queue a line                  */
  647.  
  648. #endif
  649. \Rogue\Monster\
  650. else
  651.   echo "will not over write ./src/rexx/rexxio.h"
  652. fi
  653. if [ `wc -c ./src/rexx/rexxio.h | awk '{printf $1}'` -ne 3327 ]
  654. then
  655. echo `wc -c ./src/rexx/rexxio.h | awk '{print "Got " $1 ", Expected " 3327}'`
  656. fi
  657. if `test ! -s ./src/rexx/rexxio.i`
  658. then
  659. echo "writing ./src/rexx/rexxio.i"
  660. cat > ./src/rexx/rexxio.i << '\Rogue\Monster\'
  661. * === rexx/rexxio.i ====================================================
  662. *
  663. * Copyright (c) 1986, 1987 by William S. Hawes (All Rights Reserved)
  664. *
  665. * ======================================================================
  666. * Include file for Input/Output related structures
  667.  
  668.          IFND     REXX_REXXIO_I
  669. REXX_REXXIO_I  SET   1
  670.  
  671.          IFND     REXX_STORAGE_I
  672.          INCLUDE  "rexx/storage.i"
  673.          ENDC
  674.  
  675. RXBUFFSZ EQU      204                  ; buffer length
  676.  
  677. * The IoBuff is a resource node used to maintain the File List.  Nodes are
  678. * allocated and linked into the list whenever a file is opened.
  679.  
  680.          STRUCTURE IoBuff,rr_SIZEOF    ; structure for files/strings
  681.          APTR     iobRpt               ; read/write pointer
  682.          LONG     iobRct               ; character count
  683.          LONG     iobDFH               ; DOS filehandle
  684.          APTR     iobLock              ; DOS lock
  685.          LONG     iobBct               ; buffer length
  686.          STRUCT   iobArea,RXBUFFSZ     ; buffer area
  687.          LABEL    iobSIZEOF            ; size: 256 bytes
  688.  
  689. IOBNAME  EQU      LN_NAME              ; logical name
  690. IOBMODE  EQU      rr_Arg1              ; access mode
  691. IOBEOF   EQU      rr_Arg1+1            ; EOF flag
  692. IOBPOS   EQU      rr_Arg2              ; current position
  693.  
  694. * Access mode definitions
  695. RXIO_EXIST  EQU      -1                ; an existing filehandle
  696. RXIO_STRF   EQU      0                 ; a "string file"
  697. RXIO_READ   EQU      1                 ; read-only access
  698. RXIO_WRITE  EQU      2                 ; write mode
  699. RXIO_APPEND EQU      3                 ; append mode (existing file)
  700.  
  701. * Offset anchors for SeekF()
  702. RXIO_BEGIN  EQU      -1                ; relative to start
  703. RXIO_CURR   EQU      0                 ; relative to current position
  704. RXIO_END    EQU      1                 ; relative to end
  705.  
  706. * The Library List contains just plain resource nodes.
  707. LLOFFSET EQU      rr_Arg1              ; "Query" offset
  708. LLVERS   EQU      rr_Arg2              ; library version
  709.  
  710. * The RexxClipNode structure is used to maintain the Clip List.  The
  711. * value string is stored as an argstring in the rr_Arg1 field.
  712. CLVALUE  EQU      rr_Arg1              ; value string
  713.  
  714. * A message port structure, maintained as a resource node.
  715. * The ReplyList holds packets that have been received but haven't been
  716. * replied.
  717.  
  718.          STRUCTURE RexxMsgPort,rr_SIZEOF
  719.          STRUCT   rmp_Port,MP_SIZE           ; the message port
  720.          STRUCT   rmp_ReplyList,LH_SIZE      ; messages awaiting reply 
  721.          LABEL    rmp_SIZEOF
  722.  
  723. * Device types
  724. DT_DEV   EQU      0                    ; a device
  725. DT_DIR   EQU      1                    ; an ASSIGNed directory
  726. DT_VOL   EQU      2                    ; a volume
  727.  
  728. * Private packet types
  729. ACTION_STACK   EQU   2002              ; stack a line
  730. ACTION_QUEUE   EQU   2003              ; queue a line
  731.  
  732.          ENDC
  733. \Rogue\Monster\
  734. else
  735.   echo "will not over write ./src/rexx/rexxio.i"
  736. fi
  737. if [ `wc -c ./src/rexx/rexxio.i | awk '{printf $1}'` -ne 2853 ]
  738. then
  739. echo `wc -c ./src/rexx/rexxio.i | awk '{print "Got " $1 ", Expected " 2853}'`
  740. fi
  741. if `test ! -s ./src/rexx/errors.h`
  742. then
  743. echo "writing ./src/rexx/errors.h"
  744. cat > ./src/rexx/errors.h << '\Rogue\Monster\'
  745. /* == errors.h =========================================================
  746.  *
  747.  * Copyright (c) 1987 by William S. Hawes (All Rights Reserved)
  748.  * 
  749.  * =====================================================================
  750.  * Definitions for ARexx error codes
  751.  */
  752.  
  753. #define ERRC_MSG  0                    /*  error code offset           */
  754. #define ERR10_001 (ERRC_MSG+1)         /*  program not found           */
  755. #define ERR10_002 (ERRC_MSG+2)         /*  execution halted            */
  756. #define ERR10_003 (ERRC_MSG+3)         /*  no memory available         */
  757. #define ERR10_004 (ERRC_MSG+4)         /*  invalid character in program*/
  758. #define ERR10_005 (ERRC_MSG+5)         /*  unmatched quote             */
  759. #define ERR10_006 (ERRC_MSG+6)         /*  unterminated comment        */
  760. #define ERR10_007 (ERRC_MSG+7)         /*  clause too long             */
  761. #define ERR10_008 (ERRC_MSG+8)         /*  unrecognized token          */
  762. #define ERR10_009 (ERRC_MSG+9)         /*  symbol or string too long   */
  763.  
  764. #define ERR10_010 (ERRC_MSG+10)        /*  invalid message packet      */
  765. #define ERR10_011 (ERRC_MSG+11)        /*  command string error        */
  766. #define ERR10_012 (ERRC_MSG+12)        /*  error return from function  */
  767. #define ERR10_013 (ERRC_MSG+13)        /*  host environment not found  */
  768. #define ERR10_014 (ERRC_MSG+14)        /*  required library not found  */
  769. #define ERR10_015 (ERRC_MSG+15)        /*  function not found          */
  770. #define ERR10_016 (ERRC_MSG+16)        /*  no return value             */
  771. #define ERR10_017 (ERRC_MSG+17)        /*  wrong number of arguments   */
  772. #define ERR10_018 (ERRC_MSG+18)        /*  invalid argument to function*/
  773. #define ERR10_019 (ERRC_MSG+19)        /*  invalid PROCEDURE           */
  774.  
  775. #define ERR10_020 (ERRC_MSG+20)        /*  unexpected THEN/ELSE        */
  776. #define ERR10_021 (ERRC_MSG+21)        /*  unexpected WHEN/OTHERWISE   */
  777. #define ERR10_022 (ERRC_MSG+22)        /*  unexpected LEAVE or ITERATE */
  778. #define ERR10_023 (ERRC_MSG+23)        /*  invalid statement in SELECT */
  779. #define ERR10_024 (ERRC_MSG+24)        /*  missing THEN clauses        */
  780. #define ERR10_025 (ERRC_MSG+25)        /*  missing OTHERWISE           */
  781. #define ERR10_026 (ERRC_MSG+26)        /*  missing or unexpected END   */
  782. #define ERR10_027 (ERRC_MSG+27)        /*  symbol mismatch on END      */
  783. #define ERR10_028 (ERRC_MSG+28)        /*  invalid DO syntax           */
  784. #define ERR10_029 (ERRC_MSG+29)        /*  incomplete DO/IF/SELECT     */
  785.  
  786. #define ERR10_030 (ERRC_MSG+30)        /*  label not found             */
  787. #define ERR10_031 (ERRC_MSG+31)        /*  symbol expected             */
  788. #define ERR10_032 (ERRC_MSG+32)        /*  string or symbol expected   */
  789. #define ERR10_033 (ERRC_MSG+33)        /*  invalid sub-keyword         */
  790. #define ERR10_034 (ERRC_MSG+34)        /*  required keyword missing    */
  791. #define ERR10_035 (ERRC_MSG+35)        /*  extraneous characters       */
  792. #define ERR10_036 (ERRC_MSG+36)        /*  sub-keyword conflict        */
  793. #define ERR10_037 (ERRC_MSG+37)        /*  invalid template            */
  794. #define ERR10_038 (ERRC_MSG+38)        /*  invalid TRACE request       */
  795. #define ERR10_039 (ERRC_MSG+39)        /*  uninitialized variable      */
  796.  
  797. #define ERR10_040 (ERRC_MSG+40)        /*  invalid variable name       */
  798. #define ERR10_041 (ERRC_MSG+41)        /*  invalid expression          */
  799. #define ERR10_042 (ERRC_MSG+42)        /*  unbalanced parentheses      */
  800. #define ERR10_043 (ERRC_MSG+43)        /*  nesting level exceeded      */
  801. #define ERR10_044 (ERRC_MSG+44)        /*  invalid expression result   */
  802. #define ERR10_045 (ERRC_MSG+45)        /*  expression required         */
  803. #define ERR10_046 (ERRC_MSG+46)        /*  boolean value not 0 or 1    */
  804. #define ERR10_047 (ERRC_MSG+47)        /*  arithmetic conversion error */
  805. #define ERR10_048 (ERRC_MSG+48)        /*  invalid operand             */
  806.  
  807. /* Return Codes for general use ...                                    */
  808. #define RC_FAIL   -1                   /*  something's wrong           */
  809. #define RC_OK     0                    /*  success                     */
  810. #define RC_WARN   5                    /*  warning only                */
  811. #define RC_ERROR  10                   /*  something's wrong           */
  812. #define RC_FATAL  20                   /*  complete or severe failure  */
  813. \Rogue\Monster\
  814. else
  815.   echo "will not over write ./src/rexx/errors.h"
  816. fi
  817. if [ `wc -c ./src/rexx/errors.h | awk '{printf $1}'` -ne 4334 ]
  818. then
  819. echo `wc -c ./src/rexx/errors.h | awk '{print "Got " $1 ", Expected " 4334}'`
  820. fi
  821. if `test ! -s ./src/rexx/errors.i`
  822. then
  823. echo "writing ./src/rexx/errors.i"
  824. cat > ./src/rexx/errors.i << '\Rogue\Monster\'
  825. * ========================     errors.i     =============================
  826. * Definitions for Rexx error codes
  827.  
  828. ERRC_MSG    EQU   0                 ; error code offset
  829. ERR10_001   EQU   (ERRC_MSG+1)      ; Program not found
  830. ERR10_002   EQU   (ERRC_MSG+2)      ; execution halted
  831. ERR10_003   EQU   (ERRC_MSG+3)      ; no memory available
  832. ERR10_004   EQU   (ERRC_MSG+4)      ; invalid character in program
  833. ERR10_005   EQU   (ERRC_MSG+5)      ; unmatched quote
  834. ERR10_006   EQU   (ERRC_MSG+6)      ; unterminated comment
  835. ERR10_007   EQU   (ERRC_MSG+7)      ; clause too long
  836. ERR10_008   EQU   (ERRC_MSG+8)      ; unrecognized token
  837. ERR10_009   EQU   (ERRC_MSG+9)      ; symbol or string too long
  838.  
  839. ERR10_010   EQU   (ERRC_MSG+10)     ; invalid message packet
  840. ERR10_011   EQU   (ERRC_MSG+11)     ; command string error
  841. ERR10_012   EQU   (ERRC_MSG+12)     ; error return from function
  842. ERR10_013   EQU   (ERRC_MSG+13)     ; host environment not found
  843. ERR10_014   EQU   (ERRC_MSG+14)     ; required library not available
  844. ERR10_015   EQU   (ERRC_MSG+15)     ; function not found
  845. ERR10_016   EQU   (ERRC_MSG+16)     ; function did not return value
  846. ERR10_017   EQU   (ERRC_MSG+17)     ; wrong number of arguments
  847. ERR10_018   EQU   (ERRC_MSG+18)     ; invalid argument to function
  848. ERR10_019   EQU   (ERRC_MSG+19)     ; invalid PROCEDURE instruction
  849.  
  850. ERR10_020   EQU   (ERRC_MSG+20)     ; unexpected THEN/ELSE
  851. ERR10_021   EQU   (ERRC_MSG+21)     ; unexpected WHEN/OTHERWISE
  852. ERR10_022   EQU   (ERRC_MSG+22)     ; unexpected BREAK, LEAVE or ITERATE
  853. ERR10_023   EQU   (ERRC_MSG+23)     ; invalid statement in SELECT
  854. ERR10_024   EQU   (ERRC_MSG+24)     ; missing or multiple THEN clauses
  855. ERR10_025   EQU   (ERRC_MSG+25)     ; missing OTHERWISE
  856. ERR10_026   EQU   (ERRC_MSG+26)     ; missing or unexpected END
  857. ERR10_027   EQU   (ERRC_MSG+27)     ; symbol mismatch on END/LEAVE/ITERATE
  858. ERR10_028   EQU   (ERRC_MSG+28)     ; invalid 'DO' syntax
  859. ERR10_029   EQU   (ERRC_MSG+29)     ; incomplete DO/IF/SELECT
  860.  
  861. ERR10_030   EQU   (ERRC_MSG+30)     ; label not found
  862. ERR10_031   EQU   (ERRC_MSG+31)     ; symbol expected
  863. ERR10_032   EQU   (ERRC_MSG+32)     ; string or symbol expected
  864. ERR10_033   EQU   (ERRC_MSG+33)     ; invalid sub-keyword
  865. ERR10_034   EQU   (ERRC_MSG+34)     ; required keyword missing
  866. ERR10_035   EQU   (ERRC_MSG+35)     ; extraneous characters in clause
  867. ERR10_036   EQU   (ERRC_MSG+36)     ; sub-keyword conflict
  868. ERR10_037   EQU   (ERRC_MSG+37)     ; invalid template
  869. ERR10_038   EQU   (ERRC_MSG+38)     ; invalid TRACE request
  870. ERR10_039   EQU   (ERRC_MSG+39)     ; uninitialized variable
  871.  
  872. ERR10_040   EQU   (ERRC_MSG+40)     ; invalid variable name
  873. ERR10_041   EQU   (ERRC_MSG+41)     ; invalid expression
  874. ERR10_042   EQU   (ERRC_MSG+42)     ; unbalanced parentheses
  875. ERR10_043   EQU   (ERRC_MSG+43)     ; nesting level exceeded
  876. ERR10_044   EQU   (ERRC_MSG+44)     ; invalid expression result
  877. ERR10_045   EQU   (ERRC_MSG+45)     ; expression required
  878. ERR10_046   EQU   (ERRC_MSG+46)     ; boolean value not 0 or 1
  879. ERR10_047   EQU   (ERRC_MSG+47)     ; arithmetic conversion error
  880. ERR10_048   EQU   (ERRC_MSG+48)     ; invalid operand
  881.  
  882. * Return Codes for general use ...
  883. RC_FAIL     EQU   -1                ; something's wrong
  884. RC_OK       EQU   0                 ; success
  885. RC_WARN     EQU   5                 ; A warning only
  886. RC_ERROR    EQU   10                ; Something wrong
  887. RC_FATAL    EQU   20                ; Complete or severe failure
  888. \Rogue\Monster\
  889. else
  890.   echo "will not over write ./src/rexx/errors.i"
  891. fi
  892. if [ `wc -c ./src/rexx/errors.i | awk '{printf $1}'` -ne 3437 ]
  893. then
  894. echo `wc -c ./src/rexx/errors.i | awk '{print "Got " $1 ", Expected " 3437}'`
  895. fi
  896. if `test ! -s ./src/rexx/rxsupplib.i`
  897. then
  898. echo "writing ./src/rexx/rxsupplib.i"
  899. cat > ./src/rexx/rxsupplib.i << '\Rogue\Monster\'
  900. * === rxsupplib.i ======================================================
  901. *
  902. * Copyright (c) 1986, 1987 by William S. Hawes (All Rights Reserved)
  903. *
  904. * ======================================================================
  905. * Include file for Rexx Support Library
  906.  
  907.          IFND     REXX_RXSUPPLIB_I
  908. REXX_RXSUPPLIB_I  SET   1
  909.  
  910.          IFND     REXX_STORAGE_I
  911.          INCLUDE  "rexx/storage.i"
  912.          ENDC
  913.  
  914.          IFND     REXX_RXSLIB_I
  915.          INCLUDE  "rexx/rxslib.i"
  916.          ENDC
  917.  
  918. * Structure definition for the Rexx Support Library
  919.          STRUCTURE RexxSupport,LIB_SIZE
  920.          APTR     rs_SysBase           ; EXEC base
  921.          APTR     rs_REXXBase          ; Rexx System Library base
  922.          LONG     rs_SegList           ; library seglist
  923.          LABEL    rs_SIZEOF
  924.  
  925. RSNAME   MACRO
  926.          dc.b     'rexxsupport.library',0
  927.          ENDM
  928.  
  929. RSID     MACRO
  930.          dc.b     'rexxsupport 1.0 (22 AUG 87)',13,10,0
  931.          ENDM
  932.  
  933. RSVERS   EQU   2
  934. RSREV    EQU   1
  935.  
  936. * Various system constants
  937. MemList     EQU   $142                 ; Memory list
  938. DeviceList  EQU   $15E                 ; Devices list
  939. LibList     EQU   $17A                 ; Libraries list
  940. PortList    EQU   $188                 ; Ports list
  941. ReadyList   EQU   $196                 ; Ready Tasks
  942. WaitList    EQU   $1A4                 ; Waiting Tasks
  943.  
  944.          ENDC
  945. \Rogue\Monster\
  946. else
  947.   echo "will not over write ./src/rexx/rxsupplib.i"
  948. fi
  949. if [ `wc -c ./src/rexx/rxsupplib.i | awk '{printf $1}'` -ne 1342 ]
  950. then
  951. echo `wc -c ./src/rexx/rxsupplib.i | awk '{print "Got " $1 ", Expected " 1342}'`
  952. fi
  953. if `test ! -s ./src/rexx/storage.h`
  954. then
  955. echo "writing ./src/rexx/storage.h"
  956. cat > ./src/rexx/storage.h << '\Rogue\Monster\'
  957. /* === rexx/storage.h ==================================================
  958.  *
  959.  * Copyright (c) 1986, 1987 by William S. Hawes (All Rights Reserved)
  960.  *
  961.  * =====================================================================
  962.  * Header file to define ARexx data structures.
  963.  */
  964.  
  965. #ifndef REXX_STORAGE_H
  966. #define REXX_STORAGE_H
  967.  
  968. #ifndef EXEC_TYPES_H
  969. #include "exec/types.h"
  970. #endif
  971.  
  972. #ifndef EXEC_NODES_H
  973. #include "exec/nodes.h"
  974. #endif
  975.  
  976. #ifndef EXEC_LISTS_H
  977. #include "exec/lists.h"
  978. #endif
  979.  
  980. #ifndef EXEC_PORTS_H
  981. #include "exec/ports.h"
  982. #endif
  983.  
  984. #ifndef EXEC_LIBRARIES_H
  985. #include "exec/libraries.h"
  986. #endif
  987.  
  988. /* The RexxStr structure is used to maintain the internal strings in REXX.
  989.  * It includes the buffer area for the string and associated attributes.
  990.  * This is actually a variable-length structure; it is allocated for a
  991.  * specific length string, and the length is never modified thereafter
  992.  * (since it's used for recycling).
  993.  */
  994.  
  995. struct NexxStr {
  996.    LONG     ns_Ivalue;                 /* integer value                 */
  997.    UWORD    ns_Length;                 /* length in bytes (excl null)   */
  998.    UBYTE    ns_Flags;                  /* attribute flags               */
  999.    UBYTE    ns_Hash;                   /* hash code                     */
  1000.    BYTE     ns_Buff[8];                /* buffer area for strings       */
  1001.    };                                  /* size: 16 bytes (minimum)      */
  1002.  
  1003. #define NXADDLEN 9                     /* offset plus null byte         */
  1004. #define IVALUE(nsPtr) (nsPtr->ns_Ivalue)
  1005.  
  1006. /* String attribute flag bit definitions                                */
  1007. #define NSB_KEEP     0                 /* permanent string?             */
  1008. #define NSB_STRING   1                 /* string form valid?            */
  1009. #define NSB_NOTNUM   2                 /* non-numeric?                  */
  1010. #define NSB_NUMBER   3                 /* a valid number?               */
  1011. #define NSB_BINARY   4                 /* integer value saved?          */
  1012. #define NSB_FLOAT    5                 /* floating point format?        */
  1013. #define NSB_EXT      6                 /* an external string?           */
  1014. #define NSB_SOURCE   7                 /* part of the program source?   */
  1015.  
  1016. /* The flag form of the string attributes                               */
  1017. #define NSF_KEEP     (1 << NSB_KEEP  )
  1018. #define NSF_STRING   (1 << NSB_STRING)
  1019. #define NSF_NOTNUM   (1 << NSB_NOTNUM)
  1020. #define NSF_NUMBER   (1 << NSB_NUMBER)
  1021. #define NSF_BINARY   (1 << NSB_BINARY)
  1022. #define NSF_FLOAT    (1 << NSB_FLOAT )
  1023. #define NSF_EXT      (1 << NSB_EXT   )
  1024. #define NSF_SOURCE   (1 << NSB_SOURCE)
  1025.  
  1026. /* Combinations of flags                                                */
  1027. #define NSF_INTNUM   (NSF_NUMBER | NSF_BINARY | NSF_STRING)
  1028. #define NSF_DPNUM    (NSF_NUMBER | NSF_FLOAT)
  1029. #define NSF_ALPHA    (NSF_NOTNUM | NSF_STRING)
  1030. #define NSF_OWNED    (NSF_SOURCE | NSF_EXT | NSF_KEEP)
  1031. #define KEEPSTR      (NSF_STRING | NSF_SOURCE | NSF_NOTNUM)
  1032. #define KEEPNUM      (NSF_STRING | NSF_SOURCE | NSF_NUMBER | NSF_BINARY)
  1033.  
  1034. /* The RexxArg structure is identical to the NexxStr structure, but
  1035.  * is allocated from system memory rather than from internal storage.
  1036.  * This structure is used for passing arguments to external programs.
  1037.  * It is usually passed as an "argstring", a pointer to the string buffer.
  1038.  */
  1039. struct RexxArg {
  1040.    LONG     ra_Size;                   /* total allocated length        */
  1041.    UWORD    ra_Length;                 /* length of string              */
  1042.    UBYTE    ra_Flags;                  /* attribute flags               */
  1043.    UBYTE    ra_Hash;                   /* hash code                     */
  1044.    BYTE     ra_Buff[8];                /* buffer area                   */
  1045.    };                                  /* size: 16 bytes (minimum)      */
  1046.  
  1047. /* The RexxMsg structure is used for all communications with Rexx programs.
  1048.  * It is an EXEC message with a parameter block appended.
  1049.  */
  1050.  
  1051. struct RexxMsg {
  1052.    struct Message rm_Node;             /* EXEC message structure        */
  1053.    APTR     rm_TaskBlock;              /* pointer to global structure   */
  1054.    APTR     rm_LibBase;                /* library base                  */
  1055.    LONG     rm_Action;                 /* command (action) code         */
  1056.    LONG     rm_Result1;                /* primary result (return code)  */
  1057.    LONG     rm_Result2;                /* secondary result              */
  1058.    STRPTR   rm_Args[16];               /* argument block (ARG0-ARG15)   */
  1059.  
  1060.    struct MsgPort *rm_PassPort;        /* forwarding port               */
  1061.    STRPTR   rm_CommAddr;               /* host address (port name)      */
  1062.    STRPTR   rm_FileExt;                /* file extension                */
  1063.    LONG     rm_Stdin;                  /* input stream (filehandle)     */
  1064.    LONG     rm_Stdout;                 /* output stream (filehandle)    */
  1065.    LONG     rm_avail;                  /* future expansion              */
  1066.    };                                  /* size: 128 bytes               */
  1067.  
  1068.  
  1069. /* Field definitions                                                    */
  1070. #define ARG0(rmp) (rmp->rm_Args[0])    /* start of argblock             */
  1071. #define ARG1(rmp) (rmp->rm_Args[1])    /* first argument                */
  1072. #define ARG2(rmp) (rmp->rm_Args[2])    /* second argument               */
  1073.  
  1074. #define MAXRMARG  15                   /* maximum arguments             */
  1075.  
  1076. /* Command (action) codes for message packets                           */
  1077. #define RXCOMM    0x01000000           /* a command-level invocation    */
  1078. #define RXFUNC    0x02000000           /* a function call               */
  1079. #define RXCLOSE   0x03000000           /* close the port                */
  1080. #define RXQUERY   0x04000000           /* query for information         */
  1081. #define RXADDFH   0x07000000           /* add a function host           */
  1082. #define RXADDLIB  0x08000000           /* add a function library        */
  1083. #define RXREMLIB  0x09000000           /* remove a function library     */
  1084. #define RXADDCON  0x0A000000           /* add/update a ClipList string  */
  1085. #define RXREMCON  0x0B000000           /* remove a ClipList string      */
  1086. #define RXTCOPN   0x0C000000           /* open the trace console        */
  1087. #define RXTCCLS   0x0D000000           /* close the trace console       */
  1088.  
  1089. /* Command modifier flag bits                                           */
  1090. #define RXFB_NOIO    16                /* suppress I/O inheritance?     */
  1091. #define RXFB_RESULT  17                /* result string expected?       */
  1092. #define RXFB_STRING  18                /* program is a "string file"?   */
  1093. #define RXFB_TOKEN   19                /* tokenize the command line?    */
  1094. #define RXFB_NONRET  20                /* a "no-return" message?        */
  1095.  
  1096. /* Modifier flags                                                       */
  1097. #define RXFF_RESULT  (1 << RXFB_RESULT)
  1098. #define RXFF_STRING  (1 << RXFB_STRING)
  1099. #define RXFF_TOKEN   (1 << RXFB_TOKEN )
  1100. #define RXFF_NONRET  (1 << RXFB_NONRET)
  1101.  
  1102. #define RXCODEMASK   0xFF000000
  1103. #define RXARGMASK    0x0000000F
  1104.  
  1105. /* The RexxRsrc structure is used to manage global resources.
  1106.  * The name string for each node is created as a RexxArg structure,
  1107.  * and the total size of the node is saved in the "rr_Size" field.
  1108.  * Functions are provided to allocate and release resource nodes.
  1109.  * If special deletion operations are required, an offset and base can
  1110.  * be provided in "rr_Func" and "rr_Base", respectively.  This function
  1111.  * will be called with the base in register A6 and the node in A0.
  1112.  */
  1113.  
  1114. struct RexxRsrc {
  1115.    struct Node rr_Node;
  1116.    WORD     rr_Func;                   /* "auto-delete" offset          */
  1117.    APTR     rr_Base;                   /* "auto-delete" base            */
  1118.    LONG     rr_Size;                   /* total size of node            */
  1119.    LONG     rr_Arg1;                   /* available ...                 */
  1120.    LONG     rr_Arg2;                   /* available ...                 */
  1121.    };                                  /* size: 32 bytes                */
  1122.  
  1123. /* Resource node types                                                  */
  1124. #define RRT_ANY      0                 /* any node type ...             */
  1125. #define RRT_LIB      1                 /* a function library            */
  1126. #define RRT_PORT     2                 /* a public port                 */
  1127. #define RRT_FILE     3                 /* a file IoBuff                 */
  1128. #define RRT_HOST     4                 /* a function host               */
  1129. #define RRT_CLIP     5                 /* a Clip List node              */
  1130.  
  1131. /* The RexxTask structure holds the fields used by REXX to communicate with
  1132.  * external processes, including the client task.  It includes the global
  1133.  * data structure (and the base environment).  The structure is passed to
  1134.  * the newly-created task in its "wake-up" message.
  1135.  */
  1136.  
  1137. #define GLOBALSZ  200                  /* total size of GlobalData      */
  1138.  
  1139. struct RexxTask {
  1140.    BYTE     rt_Global[GLOBALSZ];       /* global data structure         */
  1141.    struct MsgPort rt_MsgPort;          /* global message port           */
  1142.    UBYTE    rt_Flags;                  /* task flag bits                */
  1143.    BYTE     rt_SigBit;                 /* signal bit                    */
  1144.  
  1145.    APTR     rt_ClientID;               /* the client's task ID
  1146.    APTR     rt_MsgPkt;                 /* the packet being processed
  1147.    APTR     rt_TaskID;                 /* our task ID
  1148.    APTR     rt_RexxPort;               /* the REXX public port
  1149.  
  1150.    APTR     rt_ErrTrap;                /* Error trap address
  1151.    APTR     rt_StackPtr;               /* stack pointer for traps
  1152.  
  1153.    struct List rt_Header1;             /* Environment list              */
  1154.    struct List rt_Header2;             /* Memory freelist               */
  1155.    struct List rt_Header3;             /* Memory allocation list        */
  1156.    struct List rt_Header4;             /* Files list                    */
  1157.    struct List rt_Header5;             /* Message Ports List            */
  1158.    };
  1159.  
  1160. /* Definitions for RexxTask flag bits                                   */
  1161. #define RTFB_TRACE   0                 /* external trace flag           */
  1162. #define RTFB_HALT    1                 /* external halt flag            */
  1163. #define RTFB_SUSP    2                 /* suspend task?                 */
  1164. #define RTFB_TCUSE   3                 /* trace console in use?         */
  1165. #define RTFB_WAIT    6                 /* waiting for reply?            */
  1166. #define RTFB_CLOSE   7                 /* task completed?               */
  1167.  
  1168. /* Definitions for memory allocation constants                          */
  1169. #define MEMQUANT  16                   /* quantum of memory space       */
  1170. #define MEMMASK   0xFFFFFFF0           /* mask for rounding the size    */
  1171.  
  1172. #define MEMQUICK  (1 << 0 )            /* EXEC flags: MEMF_PUBLIC       */
  1173. #define MEMCLEAR  (1 << 16)            /* EXEC flags: MEMF_CLEAR        */
  1174.  
  1175. /* The SrcNode is a temporary structure used to hold values destined for a
  1176.  * segment array.  It is also used to maintain the memory freelist.
  1177.  */
  1178.  
  1179. struct SrcNode {
  1180.    struct SrcNode *sn_Succ;            /* next node                     */
  1181.    struct SrcNode *sn_Pred;
  1182.    APTR     sn_Ptr;                    /* pointer value                 */
  1183.    LONG     sn_Size;                   /* size of object                */
  1184.    };                                  /* size: 16 bytes                */
  1185.  
  1186. #endif
  1187. \Rogue\Monster\
  1188. else
  1189.   echo "will not over write ./src/rexx/storage.h"
  1190. fi
  1191. if [ `wc -c ./src/rexx/storage.h | awk '{printf $1}'` -ne 11323 ]
  1192. then
  1193. echo `wc -c ./src/rexx/storage.h | awk '{print "Got " $1 ", Expected " 11323}'`
  1194. fi
  1195. if `test ! -s ./src/rexx/storage.i`
  1196. then
  1197. echo "writing ./src/rexx/storage.i"
  1198. cat > ./src/rexx/storage.i << '\Rogue\Monster\'
  1199. * === rexx/storage.i ===================================================
  1200. *
  1201. * Copyright (c) 1986, 1987 by William S. Hawes (All Rights Reserved)
  1202. *
  1203. * ======================================================================
  1204. * Include file for REXX data structures and memory/storage management.
  1205.  
  1206.          IFND REXX_STORAGE_I
  1207. REXX_STORAGE_I SET   1
  1208.  
  1209.          IFND EXEC_TYPES_I
  1210.          INCLUDE "exec/types.i"
  1211.          ENDC
  1212.  
  1213.          IFND EXEC_NODES_I
  1214.          INCLUDE "exec/nodes.i"
  1215.          ENDC
  1216.  
  1217.          IFND EXEC_LISTS_I
  1218.          INCLUDE "exec/lists.i"
  1219.          ENDC
  1220.  
  1221.          IFND EXEC_PORTS_I
  1222.          INCLUDE "exec/ports.i"
  1223.          ENDC
  1224.  
  1225.          IFND EXEC_LIBRARIES_I
  1226.          INCLUDE "exec/libraries.i"
  1227.          ENDC
  1228.  
  1229. * The NexxStr structure is used to maintain the internal strings in REXX.
  1230. * It includes the buffer area for the string and associated attributes.
  1231. * This is actually a variable-length structure; it is allocated for a
  1232. * specific length string, and the length is never modified thereafter
  1233. * (since it's used for recycling).
  1234.  
  1235.          STRUCTURE NexxStr,0
  1236.          LONG     ns_Ivalue            ; integer value
  1237.          UWORD    ns_Length            ; length in bytes (excl null byte)
  1238.          UBYTE    ns_Flags             ; attribute flags
  1239.          UBYTE    ns_Hash              ; sum-of-characters hash code
  1240.          STRUCT   ns_Buff,8            ; buffer area for strings
  1241.          LABEL    ns_SIZEOF            ; size: 16 bytes (minimum)
  1242.  
  1243. NXADDLEN EQU      9                    ; structure offset plus null byte
  1244. IVALUE   EQU      ns_Ivalue            ; integer value
  1245.  
  1246. * String attribute flag bit definitions
  1247. NSB_KEEP    EQU   0                    ; permanent string? (in Symbol Table)
  1248. NSB_STRING  EQU   1                    ; string form valid?
  1249. NSB_NOTNUM  EQU   2                    ; non-numeric?
  1250. NSB_NUMBER  EQU   3                    ; a valid number?
  1251. NSB_BINARY  EQU   4                    ; integer value saved?
  1252. NSB_FLOAT   EQU   5                    ; floating point format?
  1253. NSB_EXT     EQU   6                    ; an external string?
  1254. NSB_SOURCE  EQU   7                    ; part of the program source?
  1255.  
  1256. * The flag form of the string attributes
  1257. NSF_KEEP    EQU   1<<NSB_KEEP
  1258. NSF_STRING  EQU   1<<NSB_STRING
  1259. NSF_NOTNUM  EQU   1<<NSB_NOTNUM
  1260. NSF_NUMBER  EQU   1<<NSB_NUMBER
  1261. NSF_BINARY  EQU   1<<NSB_BINARY
  1262. NSF_FLOAT   EQU   1<<NSB_FLOAT
  1263. NSF_EXT     EQU   1<<NSB_EXT
  1264. NSF_SOURCE  EQU   1<<NSB_SOURCE
  1265.  
  1266. * Combinations of flags 
  1267. NSF_INTNUM  EQU   (NSF_NUMBER!NSF_BINARY!NSF_STRING)
  1268. NSF_DPNUM   EQU   (NSF_NUMBER!NSF_FLOAT)
  1269. NSF_ALPHA   EQU   (NSF_NOTNUM!NSF_STRING)
  1270. NSF_OWNED   EQU   (NSF_SOURCE!NSF_EXT!NSF_KEEP)
  1271. KEEPSTR     EQU   (NSF_STRING!NSF_SOURCE!NSF_NOTNUM)
  1272. KEEPNUM     EQU   (NSF_STRING!NSF_SOURCE!NSF_NUMBER!NSF_BINARY)
  1273.  
  1274. * The RexxArg structure is identical to the NexxStr structure, but
  1275. * is allocated from system memory rather than from internal storage.
  1276. * This structure is used for passing arguments to external programs.
  1277. * It is usually passed as an "argstring", a pointer to the string buffer.
  1278.  
  1279.          STRUCTURE RexxArg,0
  1280.          LONG     ra_Size              ; total allocated length
  1281.          UWORD    ra_Length            ; length of string
  1282.          UBYTE    ra_Flags             ; attribute flags
  1283.          UBYTE    ra_Hash              ; hash code
  1284.          STRUCT   ra_Buff,8            ; buffer area
  1285.          LABEL    ra_SIZEOF            ; size: 16 bytes
  1286.  
  1287. * The RexxMsg structure is used for all communications with Rexx programs.
  1288. * It is an EXEC message with a parameter block appended.
  1289.  
  1290.          STRUCTURE RexxMsg,MN_SIZE
  1291.          APTR     rm_TaskBlock         ; pointer to RexxTask structure
  1292.          APTR     rm_LibBase           ; library pointer
  1293.          LONG     rm_Action            ; command (action) code
  1294.          LONG     rm_Result1           ; return code
  1295.          LONG     rm_Result2           ; secondary result
  1296.          STRUCT   rm_Args,16*4         ; argument block (ARG0-ARG15)
  1297.          APTR     rm_PassPort          ; forwarding port
  1298.          APTR     rm_CommAddr          ; host address (port name)
  1299.          APTR     rm_FileExt           ; file extension
  1300.          LONG     rm_Stdin             ; input stream
  1301.          LONG     rm_Stdout            ; output stream
  1302.          LONG     rm_avail             ; future expansion
  1303.          LABEL    rm_SIZEOF            ; size: 128 bytes
  1304.  
  1305. * Field definitions
  1306. ACTION   EQU      rm_Action            ; action code
  1307. RESULT1  EQU      rm_Result1           ; primary return/error level
  1308. RESULT2  EQU      rm_Result2           ; secondary return/result string
  1309. ARG0     EQU      rm_Args              ; start of argblock
  1310. ARG1     EQU      rm_Args+4            ; first argument
  1311. ARG2     EQU      rm_Args+8            ; second argument
  1312.  
  1313. MAXRMARG EQU      15                   ; maximum arguments
  1314.  
  1315. * Command (action) codes for message packets
  1316. RXCOMM   EQU      $01000000            ; a command-level invocation
  1317. RXFUNC   EQU      $02000000            ; a function call
  1318. RXCLOSE  EQU      $03000000            ; close the port
  1319. RXQUERY  EQU      $04000000            ; query for information
  1320. RXADDFH  EQU      $07000000            ; add a function host
  1321. RXADDLIB EQU      $08000000            ; add a function library
  1322. RXREMLIB EQU      $09000000            ; remove a function library
  1323. RXADDCON EQU      $0A000000            ; add/update a ClipList string
  1324. RXREMCON EQU      $0B000000            ; remove a ClipList string
  1325. RXTCOPN  EQU      $0C000000            ; open the trace console
  1326. RXTCCLS  EQU      $0D000000            ; close the trace console
  1327.  
  1328. * Command modifier flag bits
  1329. RXFB_NOIO   EQU   16                   ; suppress I/O inheritance?
  1330. RXFB_RESULT EQU   17                   ; result string expected?
  1331. RXFB_STRING EQU   18                   ; program is a "string file"?
  1332. RXFB_TOKEN  EQU   19                   ; tokenize the command line?
  1333. RXFB_NONRET EQU   20                   ; a "no-return" message?
  1334.  
  1335. * Modifier flags
  1336. RXFF_RESULT EQU   1<<RXFB_RESULT
  1337. RXFF_STRING EQU   1<<RXFB_STRING
  1338. RXFF_TOKEN  EQU   1<<RXFB_TOKEN
  1339. RXFF_NONRET EQU   1<<RXFB_NONRET
  1340.  
  1341. RXCODEMASK  EQU   $FF000000
  1342. RXARGMASK   EQU   $0000000F
  1343.  
  1344. * The RexxRsrc structure is used to manage global resources.
  1345. * The name string for each node is created as a RexxArg structure,
  1346. * and the total size of the node is saved in the "rr_Size" field.
  1347. * Functions are provided to allocate and release resource nodes.
  1348. * If special deletion operations are required, an offset and base can
  1349. * be provided in "rr_Func" and "rr_Base", respectively.  This function
  1350. * will be called with the base in register A6 and the node in A0.
  1351.  
  1352.          STRUCTURE RexxRsrc,LN_SIZE
  1353.          WORD     rr_Func              ; "auto-delete" offset
  1354.          APTR     rr_Base              ; "auto-delete" base
  1355.          LONG     rr_Size              ; total size of node
  1356.          LONG     rr_Arg1              ; available ...
  1357.          LONG     rr_Arg2              ; available ...
  1358.          LABEL    rr_SIZEOF            ; size: 32 bytes
  1359.  
  1360. * Field definitions
  1361. RRTYPE   EQU      LN_TYPE              ; node type
  1362. RRNAME   EQU      LN_NAME              ; node name (argstring)
  1363. RRSIZE   EQU      rr_Size              ; total size of node
  1364.  
  1365. * Resource node types
  1366. RRT_ANY  EQU      0                    ; any node type ...
  1367. RRT_LIB  EQU      1                    ; a function library
  1368. RRT_PORT EQU      2                    ; a public port
  1369. RRT_FILE EQU      3                    ; a file IoBuff
  1370. RRT_HOST EQU      4                    ; a function host
  1371. RRT_CLIP EQU      5                    ; a Clip List node
  1372.  
  1373. * The RexxTask structure holds the fields used by REXX to communicate with
  1374. * external processes, including the client task.  It includes the global
  1375. * data structure (and the base environment).  The structure is passed to
  1376. * the newly-created task in its "wake-up" message.
  1377.  
  1378. GLOBALSZ EQU      200                  ; space for the Global Data structure
  1379.  
  1380.          STRUCTURE RexxTask,GLOBALSZ   ; global data structure
  1381.          STRUCT   rt_MsgPort,MP_SIZE   ; message port
  1382.          UBYTE    rt_Flags             ; task flag bits
  1383.          BYTE     rt_SigBit            ; signal bit 
  1384.  
  1385.          APTR     rt_ClientID          ; the client's task ID
  1386.          APTR     rt_MsgPkt            ; the packet being processed
  1387.          APTR     rt_TaskID            ; our task ID
  1388.          APTR     rt_RexxPort          ; the REXX public port
  1389.  
  1390.          APTR     rt_ErrTrap           ; Error trap address
  1391.          APTR     rt_StackPtr          ; stack pointer for traps
  1392.  
  1393.          STRUCT   rt_Header1,LH_SIZE
  1394.          STRUCT   rt_Header2,LH_SIZE
  1395.          STRUCT   rt_Header3,LH_SIZE
  1396.          STRUCT   rt_Header4,LH_SIZE
  1397.          STRUCT   rt_Header5,LH_SIZE
  1398.          LABEL    rt_SIZEOF
  1399.  
  1400. ENVLIST  EQU      rt_Header1           ; environment list (internal)
  1401. FREELIST EQU      rt_Header2           ; freelist (internal)
  1402. MEMLIST  EQU      rt_Header3           ; allocation list (external)
  1403. FILELIST EQU      rt_Header4           ; I/O files list (external)
  1404. PORTLIST EQU      rt_Header5           ; message ports list (external)
  1405. NUMLISTS EQU      5
  1406.  
  1407. * Definitions for RexxTask flag bits
  1408. RTFB_TRACE  EQU      0                 ; external trace flag
  1409. RTFB_HALT   EQU      1                 ; external halt flag
  1410. RTFB_SUSP   EQU      2                 ; suspend task?
  1411. RTFB_TCUSE  EQU      3                 ; trace console in use?
  1412. RTFB_WAIT   EQU      6                 ; waiting for reply?
  1413. RTFB_CLOSE  EQU      7                 ; task completed?
  1414.  
  1415. * Definitions for memory allocation constants
  1416. MEMQUANT EQU      16                   ; quantum of memory space
  1417. MEMMASK  EQU      $FFFFFFF0            ; mask for rounding the size
  1418.  
  1419. MEMQUICK EQU      (1<<0)               ; EXEC flags: MEMF_PUBLIC
  1420. MEMCLEAR EQU      (1<<16)              ; EXEC flags: MEMF_CLEAR
  1421.  
  1422. * The SrcNode is a temporary structure used to hold values destined for a
  1423. * segment array.  It is also used to maintain the memory freelist.
  1424.  
  1425.          STRUCTURE SrcNode,0           ; temporary source data structure
  1426.          APTR     sn_Succ
  1427.          APTR     sn_Pred
  1428.          APTR     sn_Ptr               ; pointer value
  1429.          LONG     sn_Size              ; size of object
  1430.          LABEL    sn_SIZEOF            ; size: 16 bytes
  1431.  
  1432.          ENDC
  1433. \Rogue\Monster\
  1434. else
  1435.   echo "will not over write ./src/rexx/storage.i"
  1436. fi
  1437. if [ `wc -c ./src/rexx/storage.i | awk '{printf $1}'` -ne 10195 ]
  1438. then
  1439. echo `wc -c ./src/rexx/storage.i | awk '{print "Got " $1 ", Expected " 10195}'`
  1440. fi
  1441. if `test ! -s ./src/tags`
  1442. then
  1443. echo "writing ./src/tags"
  1444. cat > ./src/tags << '\Rogue\Monster\'
  1445. setpen cmd1.c /^setpen(
  1446. text_init cmd1.c /^text_init(
  1447. text_switch cmd1.c /^text_switch(
  1448. text_sync cmd1.c /^text_sync(
  1449. text_load cmd1.c /^text_load(
  1450. text_colno cmd1.c /^text_colno(
  1451. text_lineno cmd1.c /^text_lineno(
  1452. text_lines cmd1.c /^text_lines(
  1453. text_cols cmd1.c /^text_cols(
  1454. text_imode cmd1.c /^text_imode(
  1455. text_tabsize cmd1.c /^text_tabsize(
  1456. text_name cmd1.c /^text_name(
  1457. text_uninit cmd1.c /^text_uninit(
  1458. inversemode cmd1.c /^inversemode(
  1459. text_cursor cmd1.c /^text_cursor(
  1460. text_position cmd1.c /^text_position(
  1461. displayblock cmd1.c /^displayblock(
  1462. text_redrawblock cmd1.c /^text_redrawblock(
  1463. text_displayseg cmd1.c /^text_displayseg(
  1464. text_redisplay cmd1.c /^text_redisplay(
  1465. text_redisplaycurrline cmd1.c /^text_redisplaycurrline(
  1466. text_write cmd1.c /^text_write(
  1467. do_up cmd1.c /^do_up(
  1468. do_scrolldown cmd1.c /^do_scrolldown(
  1469. do_scrollup cmd1.c /^do_scrollup(
  1470. do_down cmd1.c /^do_down(
  1471. do_page cmd1.c /^do_page(
  1472. do_downadd cmd1.c /^do_downadd(
  1473. do_left cmd1.c /^do_left(
  1474. do_right cmd1.c /^do_right(
  1475. do_tab cmd1.c /^do_tab(
  1476. do_backtab cmd1.c /^do_backtab(
  1477. do_return cmd1.c /^do_return(
  1478. do_bs cmd1.c /^do_bs(
  1479. do_recall cmd1.c /^do_recall(
  1480. do_esc cmd1.c /^do_esc(
  1481. escapecomlinemode cmd1.c /^escapecomlinemode(
  1482. do_del cmd1.c /^do_del(
  1483. do_top cmd1.c /^do_top(
  1484. do_bottom cmd1.c /^do_bottom(
  1485. do_firstcolumn cmd1.c /^do_firstcolumn(
  1486. do_firstnb cmd1.c /^do_firstnb(
  1487. do_lastcolumn cmd1.c /^do_lastcolumn(
  1488. do_goto cmd1.c /^do_goto(
  1489. do_screentop cmd1.c /^do_screentop(
  1490. do_screenbottom cmd1.c /^do_screenbottom(
  1491. do_findstr cmd1.c /^do_findstr(
  1492. do_findr cmd1.c /^do_findr(
  1493. do_find cmd1.c /^do_find(
  1494. search_operation cmd1.c /^search_operation(
  1495. uninit_init cmd2.c /^uninit_init(
  1496. do_remeol cmd2.c /^do_remeol(
  1497. do_wleft cmd2.c /^do_wleft(
  1498. do_wright cmd2.c /^do_wright(
  1499. do_split cmd2.c /^do_split(
  1500. do_join cmd2.c /^do_join(
  1501. do_margin cmd2.c /^do_margin(
  1502. do_wordwrap cmd2.c /^do_wordwrap(
  1503. do_reformat cmd2.c /^do_reformat(
  1504. do_tabstop cmd2.c /^do_tabstop(
  1505. do_insertmode cmd2.c /^do_insertmode(
  1506. do_insline cmd2.c /^do_insline(
  1507. do_deline cmd2.c /^do_deline(
  1508. do_chfilename cmd2.c /^do_chfilename(
  1509. do_edit cmd2.c /^do_edit(
  1510. do_bsave cmd2.c /^do_bsave(
  1511. do_save cmd2.c /^do_save(
  1512. do_savetabs cmd2.c /^do_savetabs(
  1513. do_saveas cmd2.c /^do_saveas(
  1514. do_block cmd2.c /^do_block(
  1515. blockok cmd2.c /^blockok(
  1516. do_bdelete cmd2.c /^do_bdelete(
  1517. do_bcopy cmd2.c /^do_bcopy(
  1518. do_bmove cmd2.c /^do_bmove(
  1519. do_if cmd2.c /^do_if(
  1520. do_toggle cmd2.c /^do_toggle(
  1521. do_tlate cmd2.c /^do_tlate(
  1522. do_bsource cmd2.c /^do_bsource(
  1523. do_scanf cmd2.c /^do_scanf(
  1524. movetocursor cmd2.c /^movetocursor(
  1525. extend cmd2.c /^extend(
  1526. makeroom cmd2.c /^makeroom(
  1527. freelist cmd2.c /^freelist(
  1528. do_setfont cmd3.c /^do_setfont(
  1529. do_ignorecase cmd3.c /^do_ignorecase(
  1530. init_command command.c /^init_command(
  1531. do_command command.c /^do_command(
  1532. do_null command.c /^do_null(
  1533. do_source command.c /^do_source(
  1534. do_quit command.c /^do_quit(
  1535. do_execute command.c /^do_execute(
  1536. do_repeat command.c /^do_repeat(
  1537. breakout command.c /^breakout(
  1538. do_arpinsfile filereq.c /^do_arpinsfile(
  1539. do_arpload filereq.c /^do_arpload(
  1540. do_arpsave filereq.c /^do_arpsave(
  1541. fixfile filereq.c /^fixfile(
  1542. splitpath filereq.c /^splitpath(
  1543. _LVOOldOpenLibrary filereq.c /^     jsr    _LVOOldOpenLibrary(
  1544. keyctl keyboard.c /^keyctl(
  1545. dealloc_hash keyboard.c /^dealloc_hash(
  1546. resethash keyboard.c /^resethash(
  1547. returnoveride keyboard.c /^returnoveride(
  1548. addhash keyboard.c /^addhash(
  1549. remhash keyboard.c /^remhash(
  1550. keyspectomacro keyboard.c /^keyspectomacro(
  1551. do_map keyboard.c /^do_map(
  1552. do_unmap keyboard.c /^do_unmap(
  1553. do_clearmap keyboard.c /^do_clearmap(
  1554. do_savemap keyboard.c /^do_savemap(
  1555. DeadKeyConvert keyboard.c /^DeadKeyConvert(
  1556. LN keyboard.c /^    LN(
  1557. cqtoa keyboard.c /^cqtoa(
  1558. get_codequal keyboard.c /^get_codequal(
  1559. main main.c /^main(
  1560. do_iconify main.c /^do_iconify(
  1561. do_tomouse main.c /^do_tomouse(
  1562. iconify main.c /^iconify(
  1563. uniconify main.c /^uniconify(
  1564. do_newwindow main.c /^do_newwindow(
  1565. TOpenWindow main.c /^TOpenWindow(
  1566. opensharedwindow main.c /^opensharedwindow(
  1567. closesharedwindow main.c /^closesharedwindow(
  1568. getyn main.c /^getyn(
  1569. title main.c /^title(
  1570. window_title main.c /^window_title(
  1571. set_window_params main.c /^set_window_params(
  1572. exiterr main.c /^exiterr(
  1573. breakcheck main.c /^breakcheck(
  1574. breakreset main.c /^breakreset(
  1575. do_windowparm main.c /^do_windowparm(
  1576. do_resize main.c /^do_resize(
  1577. ops main.c /^ops(
  1578. menu_strip menu.c /^menu_strip(
  1579. menu_off menu.c /^menu_off(
  1580. menu_on menu.c /^menu_on(
  1581. do_menuoff menu.c /^do_menuoff(
  1582. do_menuon menu.c /^do_menuon(
  1583. menutomacro menu.c /^menutomacro(
  1584. menu_cmd menu.c /^menu_cmd(
  1585. fixmenu menu.c /^fixmenu(
  1586. do_menuclear menu.c /^do_menuclear(
  1587. do_menuadd menu.c /^do_menuadd(
  1588. do_menudelhdr menu.c /^do_menudelhdr(
  1589. do_menudel menu.c /^do_menudel(
  1590. PMAdd mods.c /^PMAdd(
  1591. PMRem mods.c /^PMRem(
  1592. PMKill mods.c /^PMKill(
  1593. do_pushmark mods.c /^do_pushmark(
  1594. do_popmark mods.c /^do_popmark(
  1595. do_swapmark mods.c /^do_swapmark(
  1596. do_purgemark mods.c /^do_purgemark(
  1597. do_ping mods.c /^do_ping(
  1598. do_pong mods.c /^do_pong(
  1599. do_undo mods.c /^do_undo(
  1600. do_ctags refs.c /^do_ctags(
  1601. do_refs refs.c /^do_refs(
  1602. searchref refs.c /^searchref(
  1603. openrexx rexx.c /^openrexx(
  1604. closerexx rexx.c /^closerexx(
  1605. do_rx rexx.c /^do_rx(
  1606. do_rx1 rexx.c /^do_rx1(
  1607. do_rx2 rexx.c /^do_rx2(
  1608. do_rxImplied rexx.c /^do_rxImplied(
  1609. do_rexx rexx.c /^do_rexx(
  1610. makemygadget subs.c /^makemygadget(
  1611. firstns subs.c /^firstns(
  1612. lastns subs.c /^lastns(
  1613. wordlen subs.c /^wordlen(
  1614. getpath subs.c /^getpath(
  1615. allocb subs.c /^allocb(
  1616. allocl subs.c /^allocl(
  1617. bmovl subs.c /^bmovl(
  1618. detab subs.c /^detab(
  1619. xefgets subs.c /^xefgets(
  1620. ncstrcmp subs.c /^ncstrcmp(
  1621. finded subs.c /^finded(
  1622.  
  1623.  
  1624. \Rogue\Monster\
  1625. else
  1626.   echo "will not over write ./src/tags"
  1627. fi
  1628. if [ `wc -c ./src/tags | awk '{printf $1}'` -ne 5534 ]
  1629. then
  1630. echo `wc -c ./src/tags | awk '{print "Got " $1 ", Expected " 5534}'`
  1631. fi
  1632. echo "Finished archive 3 of 6"
  1633. # if you want to concatenate archives, remove anything after this line
  1634. exit
  1635. -- 
  1636. Bob Page, U of Lowell CS Dept.  page@swan.ulowell.edu  ulowell!page
  1637. Have five nice days.
  1638.